<template>
  <view>
    <BackgroundBar title="海岛" :back="true"></BackgroundBar>
    <DetailSystemItem v-if="item.messageType === 'SYSTEM'" :item="item"/>
    <DetailWechatItem v-if="item.messageType === 'WECHAT'" :item="item"/>
    <DetailReplyItem v-if="item.messageType === 'REPLY'" :item="item"/>
  </view>
</template>

<script setup>
import {ref, toRefs} from "vue";
import {onLoad} from "@dcloudio/uni-app";
import BackgroundBar from "@/components/NavigationBar/background.vue";

import DetailSystemItem from './components/DetailSystemItem.vue';
import DetailWechatItem from './components/DetailWechatItem.vue';
import DetailReplyItem from './components/DetailReplyItem.vue';

const item = ref({});
onLoad((qy) => {
  item.value = JSON.parse(qy.item);
  console.log("detail item", item.value);
});


</script>

<style lang="scss">
page {
  background-color: #fff;
}
</style>
